import { Accordion, Container, Content, Header, Root } from 'native-base';
import React, { BaseSyntheticEvent } from 'react';
import { View } from 'react-native';
import { Button } from 'react-native-elements';

export default function tpl(a: <T>(action: string, ...args: unknown[]) => ((ev: BaseSyntheticEvent<T>) => void), s: (...class_names: string[]) => {}, d: (d: string) => string | unknown[]) {
	// return (
	// 	<Root>
	// 		<View>
	// 			<Button title='点击' onPress={a('a001')}></Button>
	// 		</View>
	// 	</Root>
	// );
	const dataArray = [
		{ title: "First Element", content: "Lorem ipsum dolor sit amet" },
		{ title: "Second Element", content: "Lorem ipsum dolor sit amet" },
		{ title: "Third Element", content: "Lorem ipsum dolor sit amet" }
	];
	return (
		<Root>
			<Container>
				<Header />
				<Content padder>
					<View>
						<Button title='show action-sheet' onPress={a('a001')}></Button>
					</View>
					<View>
						<Button title='show carmar picker' onPress={a('a002')}></Button>
					</View>
					<View>
						<Button title='上传文件' onPress={a('a003')}></Button>
					</View>
					<Accordion dataArray={dataArray} expanded={0} />
				</Content>
			</Container>
		</Root >
	);
}
